package mango.web.client.admin;

import java.util.ArrayList;
import java.util.List;

import mango.web.client.Vo;

import com.google.gwt.user.client.rpc.IsSerializable;

public class AdminSearchVo extends Vo implements IsSerializable {
	public String memberId;
	public String businessName;
	public String abn;
	public String businessType;
	public String other;
	public String membershipType;
	public String financialMember;
	public String annualReport;
	//public String authorisedContact;
	public String marketingGroupUsed;
	public String packsOwnProduce;
	public String marketGroup;
	public String brand;

	public String contactId;
	public String firstname;
	public String surname;
	public String BHPhone;
	public String AHPhone;
	public String fax;
	public String identifier;
	public String mobile;
	public String email;
	public String service;
	public String businessStreet;
	public String businessCity;
	public String businessState;
	public String businessCountry;
	public String businessPostCode;
	public String postalStreet;
	public String postalCity;
	public String postalState;
	public String postalCountry;
	public String postalPostCode;

	//public String orchardId;
	public String physicalLocation;
	public String postCode;
	public String state;

	//public Integer treeId;
	public String yearPlanting;
	public String varietyId;
	//public String DTR;
	//public String BTR;
	//public String area;
	//public String areaType;
	public String tree;
	//add
	public String treeTotal;

	public String status = "ACTIVE";
	
	public boolean appended = false;
	public List<String> memberIdList = new ArrayList<String>();
	public List<String> contactIdList = new ArrayList<String>();
	

	public String sqlStatus() {
		if ("active".toUpperCase().equals(this.status)) return "status like ''";
		else if ("suspended".toUpperCase().equals(this.status)) return "status like 'suspended'";
		else return "status like '%%'";
	}
}
